<template>
  <TeamCardList :team-list="teamList"></TeamCardList>
</template>

<script setup lang='ts'>
import {useRouter} from "vue-router";
import {onMounted, ref} from "vue";
import { TeamSearchMyJoin} from "../../services/api.ts";
import {showToast} from "vant";
import TeamCardList from '../../components/TeamCardList/index.vue'

const router = useRouter()
const teamList: API.TeamSearchResponse[] = ref({})

onMounted(async () => {
  const res = await TeamSearchMyJoin()
  if (res.code === 0) {
    teamList.value = res?.data
  } else {
    showToast(res.description)
  }
})


</script>
<style scoped>

</style>